package com.briup.controller;

import org.springframework.web.bind.annotation.*;

/**
 * @author Administrator
 * @version 1.0
 * @description: TODO
 * @date 2024/8/17 下午3:10
 */
@RestController
public class testContorller {

    @GetMapping("/hello")
    public String sendHello(){
        return "Hello stu";
    }

    @RequestMapping(value="/hello2",method = RequestMethod.GET,produces = "application/json;charset=UTF-8")
    public String sendHello2(){
        return "Hello stu";
    }

    @RequestMapping(value="/hello3",method = RequestMethod.GET,produces = "application/json;charset=UTF-8")
    public String sendHello3(@RequestParam Integer id){
        return "Hello stu----------------" + id;
    }

    @RequestMapping(value="/hello4/{age}",method = RequestMethod.GET,produces = "application/json;charset=UTF-8")
    public String sendHello4(@PathVariable Integer age){
        return "Hello stu----------------" + age;
    }

}
